home *** CD-ROM | disk | FTP | other *** search
/ Game.EXE 2005 November / Game.EXE_11_2005_DVD.iso / Flash Games / Defend The Tower / defendthetower.swf / scripts / frame_1 / DoAction.as
Encoding:
Text File  |  2005-09-23  |  23.1 KB  |  700 lines

  1. curhealth = 100;
  2. totalhealth = 100;
  3. curmanna = 100;
  4. totalmanna = 100;
  5. curdefendhealth = 100;
  6. totaldefendhealth = 100;
  7. up = 0;
  8. numenemies = random(10) + 10;
  9. deadenemies = 0;
  10. totalenemies = numenemies;
  11. level1 = 1;
  12. level2 = 1;
  13. level3 = 1;
  14. level4 = 1;
  15. level5 = 1;
  16. level6 = 1;
  17. time = 250 - up;
  18. ii = 10000000;
  19. pp = 99999999;
  20. z = 100000;
  21. s = 10000;
  22. ss = 1000;
  23. delay = 10;
  24. points = 500;
  25. levelon = 1;
  26. spin = false;
  27. bomb = false;
  28. wall = true;
  29. gunlevel = 1;
  30. sendinglevel = 1;
  31. paus = false;
  32. gameover = false;
  33. won = false;
  34. menue = true;
  35. playgame = false;
  36. about = false;
  37. instructions = false;
  38. inst = 1;
  39. loadd = false;
  40. intro = false;
  41. attachMovie("border","border" + pp,pp);
  42. _root["border" + pp]._x = 0;
  43. _root["border" + pp]._y = 0;
  44. _root["border" + pp]._xscale = 153;
  45. _root["border" + pp]._yscale = 160;
  46. _root["border" + pp]._alpha = 0;
  47. _root["border" + pp].onEnterFrame = function()
  48. {
  49.    if(this._alpha < 100)
  50.    {
  51.       this._alpha += 3;
  52.    }
  53. };
  54. onEnterFrame = function()
  55. {
  56.    if(levelon == 10)
  57.    {
  58.       dragonlev = true;
  59.    }
  60.    else
  61.    {
  62.       dragonlev = false;
  63.    }
  64.    if(levelon == 15)
  65.    {
  66.       shadelev = true;
  67.    }
  68.    else
  69.    {
  70.       shadelev = false;
  71.    }
  72.    if(levelon == 5)
  73.    {
  74.       bosslevel = 1;
  75.    }
  76.    else if(levelon == 10)
  77.    {
  78.       bosslevel = 2;
  79.    }
  80.    else if(levelon == 15)
  81.    {
  82.       bosslevel = 3;
  83.    }
  84.    else if(levelon == 20)
  85.    {
  86.       bosslevel = 4;
  87.    }
  88.    else
  89.    {
  90.       bosslevel = 2;
  91.    }
  92.    cost1 = level1 * 500;
  93.    cost2 = level2 * 750;
  94.    cost3 = level3 * 500;
  95.    cost4 = level4 * 750;
  96.    cost5 = level5 * 750;
  97.    cost6 = level6 * 750;
  98.    enemiesleft = numenemies - deadenemies;
  99.    if(curdefendhealth < 1 or curhealth < 1)
  100.    {
  101.       gameover = true;
  102.       paus = true;
  103.       won = false;
  104.    }
  105.    timeremaining--;
  106.    if(deadenemies == numenemies or gameover)
  107.    {
  108.       paus = true;
  109.    }
  110.    else
  111.    {
  112.       paus = false;
  113.    }
  114.    if(levelon > 20)
  115.    {
  116.       gameover = true;
  117.       won = true;
  118.    }
  119.    damage = 0.25 * gunlevel + 0.75;
  120.    if(!menue)
  121.    {
  122.       if(!about)
  123.       {
  124.          if(!instructions)
  125.          {
  126.             back.onPress = function()
  127.             {
  128.                if(curmanna > 1 && !paus && !Key.isDown(65))
  129.                {
  130.                   z++;
  131.                   attachMovie("firespeerb","firespeerb" + z,z);
  132.                   curmanna -= 1;
  133.                   _root["firespeerb" + z].low = ss - 30;
  134.                   _root["firespeerb" + z].high = ss + 30;
  135.                   _root["firespeerb" + z].stopped = false;
  136.                   _root["firespeerb" + z].xplus = xplus;
  137.                   _root["firespeerb" + z].yplus = yplus;
  138.                   _root["firespeerb" + z].explode = false;
  139.                   _root["firespeerb" + z]._rotation = _root.gun._rotation;
  140.                   _root["firespeerb" + z].gotoAndStop(1);
  141.                   _root["firespeerb" + z]._x = _root.gun._x + xSpacer;
  142.                   _root["firespeerb" + z]._y = _root.gun._y - ySpacer;
  143.                   _root["firespeerb" + z]._xscale = 20;
  144.                   _root["firespeerb" + z]._yscale = 20;
  145.                   _root["firespeerb" + z].onEnterFrame = function()
  146.                   {
  147.                      this.h = this.low;
  148.                      while(this.h < this.high)
  149.                      {
  150.                         if(_root["shadowhand" + this.h].hitTest(this) or _root["shadowdragon" + this.h].hitTest(this) or _root["mord" + this.h].hitTest(this))
  151.                         {
  152.                            this.explode = true;
  153.                            this.stopped = true;
  154.                         }
  155.                         this.h = this.h + 1;
  156.                      }
  157.                      if(this.explode && gunlevel == 1)
  158.                      {
  159.                         this.gotoAndStop(2);
  160.                         this._alpha -= 10;
  161.                      }
  162.                      else if(this.explode && gunlevel == 2)
  163.                      {
  164.                         this.gotoAndStop(2);
  165.                         this._alpha -= 10;
  166.                      }
  167.                      else if(this.explode && gunlevel == 3)
  168.                      {
  169.                         this.gotoAndStop(3);
  170.                         this._alpha -= 10;
  171.                      }
  172.                      else if(this.explode && gunlevel == 4)
  173.                      {
  174.                         this.gotoAndStop(4);
  175.                         this._alpha -= 10;
  176.                      }
  177.                      else if(this.explode && gunlevel == 5)
  178.                      {
  179.                         this.gotoAndStop(5);
  180.                         this._alpha -= 10;
  181.                      }
  182.                      else if(this.explode && gunlevel == 6)
  183.                      {
  184.                         this.gotoAndStop(6);
  185.                         this._alpha -= 10;
  186.                      }
  187.                      else if(this.explode && gunlevel == 7)
  188.                      {
  189.                         this.gotoAndStop(7);
  190.                         this._alpha -= 10;
  191.                      }
  192.                      else if(paus)
  193.                      {
  194.                         this._alpha -= 30;
  195.                      }
  196.                      if(!this.stopped)
  197.                      {
  198.                         this._x += this.xplus;
  199.                         this._y -= this.yplus;
  200.                      }
  201.                      if(!_root.back.hitTest(this._x - xSpacer,this._y + ySpacer,true) or _root.bars.hitTest(this._x + xSpacer,this._y - ySpacer,true) or this._alpha < 10)
  202.                      {
  203.                         this.removeMovieClip();
  204.                      }
  205.                   };
  206.                }
  207.             };
  208.             delay2 = random(time);
  209.             if(totalenemies < 2 && !paus && levelon == 5 && totalenemies > 0 or delay2 < 2 && !paus && levelon == 20 && totalenemies > 0)
  210.             {
  211.                totalenemies--;
  212.                ss++;
  213.                attachMovie("shadowdragon","shadowdragon" + ss,ss);
  214.                _root["shadowdragon" + ss]._xscale = 40;
  215.                _root["shadowdragon" + ss]._yscale = 40;
  216.                _root["shadowdragon" + ss]._rotation = 180;
  217.                _root["shadowdragon" + ss].life = 300;
  218.                _root["shadowdragon" + ss].gotoAndStop(1);
  219.                _root["shadowdragon" + ss]._x = 250;
  220.                _root["shadowdragon" + ss]._y = -100;
  221.                _root["shadowdragon" + ss].dying = false;
  222.                _root["shadowdragon" + ss].stopped = false;
  223.                _root["shadowdragon" + ss].low = _root.z - 30;
  224.                _root["shadowdragon" + ss].high = _root.z + 50;
  225.                _root["shadowdragon" + ss].low2 = _root.s - 15;
  226.                _root["shadowdragon" + ss].high2 = _root.s + 15;
  227.                _root["shadowdragon" + ss].onEnterFrame = function()
  228.                {
  229.                   if(!this.stopped)
  230.                   {
  231.                      this._y += 2;
  232.                      this.gotoAndStop(1);
  233.                   }
  234.                   this.i = this.low;
  235.                   while(this.i < this.high)
  236.                   {
  237.                      if(_root["firespeerb" + this.i].hitTest(this))
  238.                      {
  239.                         this.life -= damage;
  240.                      }
  241.                      this.i = this.i + 1;
  242.                   }
  243.                   this.h = this.low2;
  244.                   while(this.h < this.high2)
  245.                   {
  246.                      if(_root["spinsending" + this.h].hitTest(this) && sendinglevel > 2)
  247.                      {
  248.                         this.gotoAndStop(3);
  249.                         this.life -= 15;
  250.                      }
  251.                      this.h = this.h + 1;
  252.                   }
  253.                   if(this.life < 0 or paus)
  254.                   {
  255.                      this.dying = true;
  256.                   }
  257.                   if(this.dying && !paus)
  258.                   {
  259.                      this._alpha -= 3;
  260.                      this.stopped = true;
  261.                      this.gotoAndStop(3);
  262.                      points += 10;
  263.                   }
  264.                   else if(this.dying && paus)
  265.                   {
  266.                      this._alpha -= 10;
  267.                   }
  268.                   if(_root.two.hitTest(this) && !this.dying)
  269.                   {
  270.                      curhealth -= 0.1;
  271.                      this.stopped = true;
  272.                      this.gotoAndStop(2);
  273.                   }
  274.                   if(this._alpha < 0)
  275.                   {
  276.                      this.removeMovieClip();
  277.                      deadenemies++;
  278.                   }
  279.                };
  280.             }
  281.             if(delay2 == 7 && !paus && levelon > 6 && totalenemies > 0 or delay2 > 10 && delay2 < 16 && !paus && dragonlev && totalenemies > 0)
  282.             {
  283.                ss++;
  284.                totalenemies--;
  285.                attachMovie("shadowdragon","shadowdragon" + ss,ss);
  286.                _root["shadowdragon" + ss]._xscale = 20;
  287.                _root["shadowdragon" + ss]._yscale = 20;
  288.                _root["shadowdragon" + ss]._rotation = 180;
  289.                _root["shadowdragon" + ss].life = 60;
  290.                _root["shadowdragon" + ss].gotoAndStop(1);
  291.                _root["shadowdragon" + ss]._x = random(300) + 100;
  292.                _root["shadowdragon" + ss]._y = -100;
  293.                _root["shadowdragon" + ss].dying = false;
  294.                _root["shadowdragon" + ss].stopped = false;
  295.                _root["shadowdragon" + ss].low = _root.z - 30;
  296.                _root["shadowdragon" + ss].high = _root.z + 50;
  297.                _root["shadowdragon" + ss].low2 = _root.s - 15;
  298.                _root["shadowdragon" + ss].high2 = _root.s + 15;
  299.                _root["shadowdragon" + ss].onEnterFrame = function()
  300.                {
  301.                   if(!this.stopped)
  302.                   {
  303.                      this._y += 6;
  304.                      this.gotoAndStop(1);
  305.                   }
  306.                   this.i = this.low;
  307.                   while(this.i < this.high)
  308.                   {
  309.                      if(_root["firespeerb" + this.i].hitTest(this))
  310.                      {
  311.                         this.life -= damage;
  312.                      }
  313.                      this.i = this.i + 1;
  314.                   }
  315.                   this.h = this.low2;
  316.                   while(this.h < this.high2)
  317.                   {
  318.                      if(_root["spinsending" + this.h].hitTest(this) && sendinglevel > 2)
  319.                      {
  320.                         this.gotoAndStop(3);
  321.                         this.dying = true;
  322.                      }
  323.                      else if(_root["spinsending" + this.h].hitTest(this) && sendinglevel < 3)
  324.                      {
  325.                         this.life -= 2;
  326.                      }
  327.                      this.h = this.h + 1;
  328.                   }
  329.                   if(this.life < 0 or paus)
  330.                   {
  331.                      this.dying = true;
  332.                   }
  333.                   if(this.dying && !paus)
  334.                   {
  335.                      this._alpha -= 3;
  336.                      this.stopped = true;
  337.                      this.gotoAndStop(3);
  338.                      points += 3;
  339.                   }
  340.                   else if(this.dying && paus)
  341.                   {
  342.                      this._alpha -= 10;
  343.                   }
  344.                   if(_root.two.hitTest(this) && !this.dying)
  345.                   {
  346.                      curhealth -= 0.2;
  347.                      this.stopped = true;
  348.                      this.gotoAndStop(2);
  349.                   }
  350.                   if(this._y > 600)
  351.                   {
  352.                      curdefendhealth -= 15;
  353.                      this.removeMovieClip();
  354.                      deadenemies++;
  355.                   }
  356.                   if(this._alpha < 0)
  357.                   {
  358.                      this.removeMovieClip();
  359.                      deadenemies++;
  360.                   }
  361.                };
  362.             }
  363.             if(delay2 < 4 && !paus && delay2 > 0 && !paus && numenemies > 0 && totalenemies > 0 && !dragonlev)
  364.             {
  365.                ss++;
  366.                totalenemies--;
  367.                attachMovie("shadowhand","shadowhand" + ss,ss);
  368.                _root["shadowhand" + ss]._xscale = 20;
  369.                _root["shadowhand" + ss]._yscale = 20;
  370.                _root["shadowhand" + ss]._rotation = 180;
  371.                _root["shadowhand" + ss].gotoAndStop(1);
  372.                _root["shadowhand" + ss]._x = random(400) + 50;
  373.                _root["shadowhand" + ss]._y = -100;
  374.                if(!shadelev)
  375.                {
  376.                   _root["shadowhand" + ss].life = 8;
  377.                }
  378.                else if(shadelev)
  379.                {
  380.                   _root["shadowhand" + ss].life = 80;
  381.                }
  382.                _root["shadowhand" + ss].dying = false;
  383.                _root["shadowhand" + ss].stopped = false;
  384.                _root["shadowhand" + ss].low = _root.z - 30;
  385.                _root["shadowhand" + ss].high = _root.z + 50;
  386.                _root["shadowhand" + ss].low2 = _root.s - 15;
  387.                _root["shadowhand" + ss].high2 = _root.s + 15;
  388.                _root["shadowhand" + ss].onEnterFrame = function()
  389.                {
  390.                   if(!this.stopped)
  391.                   {
  392.                      this._y += 4;
  393.                      this.gotoAndStop(1);
  394.                   }
  395.                   this.i = this.low;
  396.                   while(this.i < this.high)
  397.                   {
  398.                      if(_root["firespeerb" + this.i].hitTest(this))
  399.                      {
  400.                         this.gotoAndStop(3);
  401.                         this.life -= damage;
  402.                      }
  403.                      this.i = this.i + 1;
  404.                   }
  405.                   this.h = this.low2;
  406.                   while(this.h < this.high2)
  407.                   {
  408.                      if(_root["spinsending" + this.h].hitTest(this))
  409.                      {
  410.                         this.gotoAndStop(3);
  411.                         this.dying = true;
  412.                      }
  413.                      this.h = this.h + 1;
  414.                   }
  415.                   if(paus or this.life < 0)
  416.                   {
  417.                      this.dying = true;
  418.                   }
  419.                   if(this.dying && !paus)
  420.                   {
  421.                      this._alpha -= 3;
  422.                      this.stopped = true;
  423.                      points += 1;
  424.                   }
  425.                   else if(this.dying && paus)
  426.                   {
  427.                      this._alpha -= 10;
  428.                   }
  429.                   if(_root.tower.hitTest(this) && !this.dying)
  430.                   {
  431.                      curhealth -= 0.05;
  432.                      this.stopped = true;
  433.                      this.gotoAndStop(2);
  434.                   }
  435.                   if(this._y > 600)
  436.                   {
  437.                      curdefendhealth -= 5;
  438.                      this.removeMovieClip();
  439.                      deadenemies++;
  440.                   }
  441.                   if(this._alpha < 0)
  442.                   {
  443.                      this.removeMovieClip();
  444.                      deadenemies++;
  445.                   }
  446.                };
  447.             }
  448.             delay2 = random(time);
  449.             if(delay2 == 5 && !paus && levelon > 2 && numenemies > 0 && totalenemies > 0 && !dragonlev or delay2 == 6 && !paus && levelon > 4 && numenemies > 0 && totalenemies > 0 && !dragonlev)
  450.             {
  451.                ss++;
  452.                totalenemies--;
  453.                attachMovie("mord","mord" + ss,ss);
  454.                _root["mord" + ss]._xscale = 20;
  455.                _root["mord" + ss]._yscale = 20;
  456.                _root["mord" + ss]._rotation = 180;
  457.                _root["mord" + ss].life = 40;
  458.                _root["mord" + ss].gotoAndStop(1);
  459.                _root["mord" + ss]._x = random(400) + 50;
  460.                _root["mord" + ss]._y = -100;
  461.                _root["mord" + ss].dying = false;
  462.                _root["mord" + ss].stopped = false;
  463.                _root["mord" + ss].low = _root.z - 30;
  464.                _root["mord" + ss].high = _root.z + 50;
  465.                _root["mord" + ss].low2 = _root.s - 15;
  466.                _root["mord" + ss].high2 = _root.s + 15;
  467.                _root["mord" + ss].onEnterFrame = function()
  468.                {
  469.                   if(!this.stopped)
  470.                   {
  471.                      this._y += 3;
  472.                      this.gotoAndStop(1);
  473.                   }
  474.                   this.i = this.low;
  475.                   while(this.i < this.high)
  476.                   {
  477.                      if(_root["firespeerb" + this.i].hitTest(this))
  478.                      {
  479.                         this.life -= damage;
  480.                      }
  481.                      this.i = this.i + 1;
  482.                   }
  483.                   this.h = this.low2;
  484.                   while(this.h < this.high2)
  485.                   {
  486.                      if(_root["spinsending" + this.h].hitTest(this) && sendinglevel > 1)
  487.                      {
  488.                         this.gotoAndStop(3);
  489.                         this.dying = true;
  490.                      }
  491.                      else if(_root["spinsending" + this.h].hitTest(this) && sendinglevel < 2)
  492.                      {
  493.                         this.life -= 2;
  494.                      }
  495.                      this.h = this.h + 1;
  496.                   }
  497.                   if(this.life < 0 or paus)
  498.                   {
  499.                      this.dying = true;
  500.                   }
  501.                   if(this.dying && !paus)
  502.                   {
  503.                      this._alpha -= 3;
  504.                      this.stopped = true;
  505.                      this.gotoAndStop(3);
  506.                      points += 2;
  507.                   }
  508.                   else if(this.dying && paus)
  509.                   {
  510.                      this._alpha -= 10;
  511.                   }
  512.                   if(_root.one.hitTest(this) && !this.dying)
  513.                   {
  514.                      curhealth -= 0.15;
  515.                      this.stopped = true;
  516.                      this.gotoAndStop(2);
  517.                   }
  518.                   if(this._y > 600)
  519.                   {
  520.                      curdefendhealth -= 10;
  521.                      this.removeMovieClip();
  522.                      deadenemies++;
  523.                   }
  524.                   if(this._alpha < 0)
  525.                   {
  526.                      this.removeMovieClip();
  527.                      deadenemies++;
  528.                   }
  529.                };
  530.             }
  531.             if(Key.isDown(65) && delay < -5 && curmanna > 10 && !paus)
  532.             {
  533.                s++;
  534.                delay = 5;
  535.                curmanna -= 10;
  536.                attachMovie("spinsending","spinsending" + s,s);
  537.                _root["spinsending" + s]._alpha = 4;
  538.                _root["spinsending" + s]._xscale = 40;
  539.                _root["spinsending" + s]._yscale = 40;
  540.                _root["spinsending" + s]._y = 300;
  541.                _root["spinsending" + s]._x = _xmouse;
  542.                _root["spinsending" + s].attack = false;
  543.                _root["spinsending" + s].stopped = false;
  544.                _root["spinsending" + s].delay = 200;
  545.                if(sendinglevel == 3)
  546.                {
  547.                   _root["spinsending" + s].delay2 = 20;
  548.                }
  549.                else
  550.                {
  551.                   _root["spinsending" + s].delay2 = 3;
  552.                }
  553.                _root["spinsending" + s].low = ss - 30;
  554.                _root["spinsending" + s].high = ss + 30;
  555.                _root["spinsending" + s].onEnterFrame = function()
  556.                {
  557.                   this.h = this.low;
  558.                   while(this.h < this.high)
  559.                   {
  560.                      if(_root["shadowhand" + this.h].hitTest(this) or _root["shadowdragon" + this.h].hitTest(this) or _root["mord" + this.h].hitTest(this))
  561.                      {
  562.                         this.attack = true;
  563.                         this.stopped = true;
  564.                      }
  565.                      this.h = this.h + 1;
  566.                   }
  567.                   if(this.stopped or paus)
  568.                   {
  569.                      this.delay -= 75;
  570.                   }
  571.                   this.delay = this.delay - 1;
  572.                   if(this._alpha < 100 && !this.attack)
  573.                   {
  574.                      this._alpha += 2;
  575.                      this.gotoAndStop(1);
  576.                   }
  577.                   if(!this.attack && this._alpha > 98 && !stopped)
  578.                   {
  579.                      this.gotoAndStop(2);
  580.                      this._y -= 2;
  581.                   }
  582.                   if(this.attack && this._alpha > 30 && sendinglevel == 1)
  583.                   {
  584.                      this.gotoAndStop(3);
  585.                      this._rotation += 30;
  586.                   }
  587.                   else if(this.attack && this._alpha > 30 && sendinglevel == 2)
  588.                   {
  589.                      this.gotoAndStop(4);
  590.                   }
  591.                   else if(this.attack && this._alpha > 30 && sendinglevel == 3)
  592.                   {
  593.                      this.gotoAndStop(5);
  594.                   }
  595.                   if(this.delay < 0)
  596.                   {
  597.                      this.delay2 = this.delay2 - 1;
  598.                      if(this.delay2 < 0)
  599.                      {
  600.                         this._alpha -= 10;
  601.                      }
  602.                   }
  603.                   if(!_root.back.hitTest(this._x,this._y,true) or this._alpha < 2)
  604.                   {
  605.                      this.removeMovieClip();
  606.                   }
  607.                };
  608.             }
  609.          }
  610.       }
  611.    }
  612.    if(curmanna < 20)
  613.    {
  614.       recharge = 0.05;
  615.    }
  616.    else
  617.    {
  618.       recharge = 0.1;
  619.    }
  620.    delay--;
  621.    delay2--;
  622.    xplus = _root.gun.xSpeed;
  623.    yplus = _root.gun.ySpeed;
  624.    xSpacer = 5 * xplus;
  625.    ySpacer = 5 * yplus;
  626.    curmanna += recharge;
  627.    if(curdefendhealth < 0)
  628.    {
  629.       curdefendhealth = 0;
  630.    }
  631.    if(curdefendhealth > totaldefendhealth)
  632.    {
  633.       curdefendhealth = totaldefendhealth;
  634.    }
  635.    perdefendhealth = curdefendhealth / totaldefendhealth * 100;
  636.    if(curhealth < 0)
  637.    {
  638.       curhealth = 0;
  639.    }
  640.    if(curhealth > totalhealth)
  641.    {
  642.       curhealth = totalhealth;
  643.    }
  644.    perhealth = curhealth / totalhealth * 100;
  645.    if(curmanna < 0)
  646.    {
  647.       curmanna = 0;
  648.    }
  649.    if(curmanna > totalmanna)
  650.    {
  651.       curmanna = totalmanna;
  652.    }
  653.    permanna = curmanna / totalmanna * 100;
  654.    if(loadd)
  655.    {
  656.       if(intro)
  657.       {
  658.          if(menue)
  659.          {
  660.             gotoAndStop(4);
  661.          }
  662.          else if(!menue && playgame)
  663.          {
  664.             if(paus && !gameover)
  665.             {
  666.                gotoAndStop(6);
  667.             }
  668.             else if(!paus && !gameover)
  669.             {
  670.                gotoAndStop(5);
  671.             }
  672.             else if(gameover && won)
  673.             {
  674.                gotoAndStop(8);
  675.             }
  676.             else if(gameover && !won)
  677.             {
  678.                gotoAndStop(7);
  679.             }
  680.          }
  681.          else if(!menue && instructions)
  682.          {
  683.             gotoAndStop(8 + inst);
  684.          }
  685.          else if(!menue && about)
  686.          {
  687.             null;
  688.          }
  689.       }
  690.       else if(!intro)
  691.       {
  692.          gotoAndStop(3);
  693.       }
  694.    }
  695.    else if(!loadd)
  696.    {
  697.       gotoAndStop(2);
  698.    }
  699. };
  700.